#ifndef TCPSOCKET_H
#define TCPSOCKET_H
#include<QWidget>
#include <QTcpSocket>
#include<QString>
#include<QByteArray>

class Tcpsocket : public QTcpSocket
{
    Q_OBJECT
public:
    Tcpsocket(QWidget *parent,qintptr p);

signals:
    void dataready(const QString &ip,const QByteArray &data);
private slots:

    void recedata();    //接收数据
    void senddata(int id, const QByteArray data); //发送
public slots:
};

#endif // TCPSOCKET_H
